﻿<UserControl x:Class="TaskbarConcepts.Thumbnail"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
             mc:Ignorable="d">
  <Grid>
    <Grid.RowDefinitions>
      <RowDefinition Height="Auto" />
      <RowDefinition Height="Auto" />
      <RowDefinition Height="Auto" />
      <RowDefinition Height="Auto" />
    </Grid.RowDefinitions>
    <Grid.ColumnDefinitions>
      <ColumnDefinition Width="*" />
      <ColumnDefinition Width="*" />
    </Grid.ColumnDefinitions>
    <Grid HorizontalAlignment="Left">
      <Grid.RowDefinitions>
        <RowDefinition Height="Auto" />
        <RowDefinition Height="Auto" />
        <RowDefinition Height="Auto" />
        <RowDefinition Height="*" />
      </Grid.RowDefinitions>
      <Rectangle Style="{DynamicResource BorderStyle}" Grid.RowSpan="4" />
      <TextBlock Text="Tabbed Thumbnail" Margin="{DynamicResource BoxedContentMargin}"
                 Style="{DynamicResource SectionTitle}" />
      <StackPanel Width="200" Grid.Row="2" Height="Auto" Margin="{DynamicResource BoxedContentMargin}">
        <Image Source="pack://application:,,,/assets/smiley.png" x:Name="image"/>
        <Button x:Name="createThumbnail" Content="Add as thumbnail" Click="createThumbnail_Click"/>
        <Button x:Name="updateImage" Content="Update image" Click="updateImage_Click"/>
        <Button x:Name="invalidateThumbnail" Content="Invalidate thumbnail" Click="invalidateThumbnail_Click" />
        <Button x:Name="removeThumbnail" Content="Remove thumbnail" Click="removeThumbnail_Click" />
      </StackPanel>
    </Grid>
    <Grid Grid.Column="1" HorizontalAlignment="Right">
      <Grid.RowDefinitions>
        <RowDefinition Height="Auto" />
        <RowDefinition Height="Auto" />
        <RowDefinition Height="Auto" />
        <RowDefinition Height="*" />
      </Grid.RowDefinitions>
      <Rectangle Style="{DynamicResource BorderStyle}" Grid.RowSpan="4" />
      <TextBlock Text="Thumbnail with Callback " Margin="{DynamicResource BoxedContentMargin}"
                 Style="{DynamicResource SectionTitle}" />
      <TextBlock Text="We will make a thumbnail preview of this black border" Grid.Row="1"
                 TextWrapping="Wrap" Width="200"
                 Margin="{DynamicResource BoxedContentMargin}"/>
      <StackPanel Grid.Row="2" Margin="{DynamicResource BoxedContentMargin}">
        <Border x:Name="trickyBorder" Background="Black" Height="200" />
        <Button x:Name="createOnDemandThumbNail" Content="Add as thumbnail" Click="createOnDemandThumbnail_Click"/>
        <Button x:Name="removeOnDemandThumbNail" Content="Remove thumbnail" Click="removeOnDemandThumbnail_Click"/>
      </StackPanel>
    </Grid>
  </Grid>
</UserControl>
